CellSVD($A[M][N]$ : row major matrix, $R$ : block size)
\begin{algorithmic}
\FOR{$i=1$ to $M$}
  \STATE $S[i] = A[i]^T A[i]$
\ENDFOR
\STATE $K = \lceil M / R \rceil$
\STATE $\delta = \epsilon \sum_{i=1}^{M}S[i]$
\REPEAT
  \STATE $converged \gets true$
  \FOR[for each diagonal]{$i=1$ to $K$} %\COMMENT{for each diagonal}
    \FOR[for each element on the diagonal]{$j=0$ to $K-i$} %\COMMENT{for each element on the diagonal}
      \STATE $lb_i \gets j \cdot R$
      \STATE $ub_i \gets min(lb_i + R, M)$
      \STATE $lb_j \gets (i + j) \cdot R$
      \STATE $ub_j \gets min(lb_j + R, M)$
      \STATE \COMMENT {Assign job asynchronously, to a free processing unit}
      \STATE $ProcessWork(A, lb_i, ub_i, lb_j, ub_j, \delta, converged)$
    \ENDFOR
    \STATE Wait until all currently assigned jobs are finished
  \ENDFOR
\UNTIL{converged = true}
\FOR{$i=1$ to $M$}
  \STATE $\sigma[i] = \sqrt{A[i]^T A[i]}$
\ENDFOR
\end{algorithmic}

